# -*- coding: utf-8 -*-

class WizPages(object):
  
  class __Data:
    def __init__(self):
      self.page1 = None   # excel file name
      self.page2 = None   # excel data
      self.page3 = None   # pick a mapping
      self.page4 = None   # do map
      self.page5 = None   # new col
      self.page6 = None   # save
      self.built = None
      self.newbuild = None


    def setmapping(self,k,v):
      self.mapping[k]=v

  instance = None
  
  def __new__(cls):
    if not WizPages.instance:
      WizPages.instance =WizPages.__Data()              
    return WizPages.instance
  

  
  def __getattr__(self, name):
    return getattr(self.instance, name)
    
  def __setattr__(self, name):
    return setattr(self.instance, name)    


def test():
  data = WizPages()
  #print data
  data.page1 ="it'myfile"
  #data.setfile('my - file')
  dat = WizPages()
  dat.page2 = 'aidear'
  #print dat
  print dat.page1
  print data.page2
 


if __name__ == "__main__":
    test()
